SlideShare a Scribd company logo
1 of 44
YouTube API: Dive-In HigEdWebDev 2009 Ron West
Google's mission  …is to organize the world's information and make it universally accessible and useful. Sometimes making information accessible requires making it available in contexts other than a web browser.
Agenda Introduction Getting Started Get Content Interaction Pulling it Together Developer Community
Introduction YouTube in Review REST Google Data API YouTube Data API Entries/Feeds Authentication
YouTube in Review Videos Comments Ratings Users Categories Keywords/Tags Channels Subscriptions ,[object Object]
Activity Feeds
Recommendations
Friends
Related Videos
Captions
Favorites
Insight Data,[object Object]
REST Client-Server Stateless Cacheable Uniform Interface Layered
REST HTTP Methods Get = List or Retrieve Put = Replace or Update Post = Create Delete = Delete
Pros  ,[object Object]
Lanugage, platform and transport agnostic
Built in error handlingCons ,[object Object]
Harder to develop with (requires tools)SOAP (RPC/Doc Literal) Web Services
Multiple Endpoints Pros ,[object Object]
Simpler to develop than SOAP
ConciseCons ,[object Object]
Tied to HTTP transportREST Web Services
Get API URL’s for: ,[object Object]
Related Videos
Ratings
Mobile
Versions
 Get Video(s)
 Edit Video
Delete Video,[object Object]
Response Codes Same response codes for HTTP 200, 201, 301, 400, 500 etc.. Codes have similar meaning for each type of call 200 (OK) 400 (Bad Request) 401 (Not Authorized) 404 (Not Found) 500 (Internal Error) Accompanied with error details (XML in payload)
YouTube Data API Version 1 Version 2 (recommended)
YouTubeData API Search for Videos Keywords (tags) Categories Query Params (metadata) Search for Playlists Keywords (tags) Categories Search for Channels Keywords (tags) Categories
YouTube Data API Retrieve Videos Comments Captions Related Videos Video Responses Categories Keywords Playlists Subscriptions Profiles Contacts Messages Activity Feeds Insight Data Feed Favorites
YouTube Data API (cont.) Create Videos Comments Captions Related Videos Video Responses Complaint Rating Contact Message Favorite Playlist Subscription
YouTube Data API (cont.) Update Video Metadata Captions Profiles Playlists Contacts Delete Video Message Favorite Playlist Subscription Contact
YouTube Data API Batch Processing Process multiple types of calls in a single request Each Request in its own <entry> tag
Sample Interaction Query API for videos tagged with “SHU” Display Videos in List Allow user to Select Video to Display Display Single Video Retrieve Comments for that Video Post Comment Login Add to Playlist
Feed <feed [namespaces]> 	… metadata … 	<openSearch:totalResults /> 	<openSearch:startIndex /> 	<openSearch: itemsPerPage /> 	<entry> 		… metadata … 		<media:group/> 	</entry> 	 <entry> 		… metadata … 		<media:group/> 	</entry> 	… </feed>
Entry (video) <entry [namespaces]> 	<title/> 	<content/> 	… metadata … 	<link  rel=“http://gdata.youtube.com/schemas/2007#video.responses “/> 	<link rel=“http://gdata.youtube.com/schemas/2007#video.related” /> 	<link rel=“http://gdata.youtube.com/schemas/2007#mobile”/> 	<media:group> 		<media:contentyt:format=“t” url=“…”/> 		<media:thumbnailurl=“…” width=“…” height=“…”/> 		<yt: duration /> 		<yt:videoid /> 	</ media:group > </entry>
Authentication AuthSub – YouTube Authentication with “callback” API [difficult] OAuth – Standardized Approach (similar in nature to OpenID) [most difficult] ClientLogin – Custom Authentication – you call YouTube API track token [easiest]
Getting Started Google Developers Key Development Environment Samples
Google Developers Key http://code.google.com/apis/youtube/dashboard/
Development Environment Accessing dev servers Plugging in Developers Key

More Related Content

Viewers also liked

4w 1h with youtube api
4w 1h with youtube api4w 1h with youtube api
4w 1h with youtube apiOue Ekasit
 
YouTube API Japan UG #1
YouTube API Japan UG #1YouTube API Japan UG #1
YouTube API Japan UG #1Yukio Andoh
 
Youtube IFrame Player API
Youtube IFrame Player APIYoutube IFrame Player API
Youtube IFrame Player APIRyan Chung
 
IT-youtube Presentation
IT-youtube PresentationIT-youtube Presentation
IT-youtube Presentationsafiya999
 
Why APIs are Different Than Integration
Why APIs are Different Than IntegrationWhy APIs are Different Than Integration
Why APIs are Different Than IntegrationApigee | Google Cloud
 
Youtube Presentation
Youtube PresentationYoutube Presentation
Youtube Presentationtownsend
 
YouTube Presentation
YouTube PresentationYouTube Presentation
YouTube Presentationguest786f62
 
The Day The Earth Broke Into Two...A Jataka Story
The Day The Earth Broke Into Two...A Jataka StoryThe Day The Earth Broke Into Two...A Jataka Story
The Day The Earth Broke Into Two...A Jataka StoryOH TEIK BIN
 
Wisdom From A Laugh 145, 146
Wisdom From A Laugh 145, 146Wisdom From A Laugh 145, 146
Wisdom From A Laugh 145, 146OH TEIK BIN
 
DESIGN IT! Talk #001 (UX) Yukio Andoh
DESIGN IT! Talk #001 (UX) Yukio AndohDESIGN IT! Talk #001 (UX) Yukio Andoh
DESIGN IT! Talk #001 (UX) Yukio AndohYukio Andoh
 
Scaling APIs: Predict, Prepare for, Overcome the Challenges
Scaling APIs: Predict, Prepare for, Overcome the ChallengesScaling APIs: Predict, Prepare for, Overcome the Challenges
Scaling APIs: Predict, Prepare for, Overcome the ChallengesApigee | Google Cloud
 
Presentation - you tube
Presentation - you tubePresentation - you tube
Presentation - you tubesunil.dce
 

Viewers also liked (16)

4w 1h with youtube api
4w 1h with youtube api4w 1h with youtube api
4w 1h with youtube api
 
Api vortrag
Api vortragApi vortrag
Api vortrag
 
YouTube API Japan UG #1
YouTube API Japan UG #1YouTube API Japan UG #1
YouTube API Japan UG #1
 
Youtube IFrame Player API
Youtube IFrame Player APIYoutube IFrame Player API
Youtube IFrame Player API
 
IT-youtube Presentation
IT-youtube PresentationIT-youtube Presentation
IT-youtube Presentation
 
Why APIs are Different Than Integration
Why APIs are Different Than IntegrationWhy APIs are Different Than Integration
Why APIs are Different Than Integration
 
Youtube Presentation
Youtube PresentationYoutube Presentation
Youtube Presentation
 
YouTube Powerpoint
YouTube PowerpointYouTube Powerpoint
YouTube Powerpoint
 
YouTube Presentation
YouTube PresentationYouTube Presentation
YouTube Presentation
 
The Day The Earth Broke Into Two...A Jataka Story
The Day The Earth Broke Into Two...A Jataka StoryThe Day The Earth Broke Into Two...A Jataka Story
The Day The Earth Broke Into Two...A Jataka Story
 
Wisdom From A Laugh 145, 146
Wisdom From A Laugh 145, 146Wisdom From A Laugh 145, 146
Wisdom From A Laugh 145, 146
 
DESIGN IT! Talk #001 (UX) Yukio Andoh
DESIGN IT! Talk #001 (UX) Yukio AndohDESIGN IT! Talk #001 (UX) Yukio Andoh
DESIGN IT! Talk #001 (UX) Yukio Andoh
 
Effective writing
Effective writingEffective writing
Effective writing
 
Scaling APIs: Predict, Prepare for, Overcome the Challenges
Scaling APIs: Predict, Prepare for, Overcome the ChallengesScaling APIs: Predict, Prepare for, Overcome the Challenges
Scaling APIs: Predict, Prepare for, Overcome the Challenges
 
Approval Template
Approval TemplateApproval Template
Approval Template
 
Presentation - you tube
Presentation - you tubePresentation - you tube
Presentation - you tube
 

Similar to YouTube API: Dive In

SEO And Podcasting Presentation
SEO And Podcasting PresentationSEO And Podcasting Presentation
SEO And Podcasting PresentationJordan Kasteler
 
Seo And Podcasting Presentation
Seo And Podcasting PresentationSeo And Podcasting Presentation
Seo And Podcasting PresentationJordan Kasteler
 
SMX@adtech: Mobile, Local and Video Search — Drew Hubbard
SMX@adtech: Mobile, Local and Video Search — Drew HubbardSMX@adtech: Mobile, Local and Video Search — Drew Hubbard
SMX@adtech: Mobile, Local and Video Search — Drew Hubbardadtech_fan
 
Multimedia Accessibility - CALRG '09
Multimedia Accessibility - CALRG '09Multimedia Accessibility - CALRG '09
Multimedia Accessibility - CALRG '09Nick Freear
 
MALT Wiki and oEmbed
MALT Wiki and oEmbedMALT Wiki and oEmbed
MALT Wiki and oEmbedNick Freear
 
API-Craft NYC - Overview of the Twitter APIs with demos
API-Craft NYC - Overview of the Twitter APIs with demosAPI-Craft NYC - Overview of the Twitter APIs with demos
API-Craft NYC - Overview of the Twitter APIs with demosTwitter Developers
 
Drupal Camp 2009 Pune Ilovebollycase Study 1233568636712224 1
Drupal Camp 2009 Pune Ilovebollycase Study 1233568636712224 1Drupal Camp 2009 Pune Ilovebollycase Study 1233568636712224 1
Drupal Camp 2009 Pune Ilovebollycase Study 1233568636712224 1gauravkumar87
 
Supercharging WordPress for SEO
Supercharging WordPress for SEOSupercharging WordPress for SEO
Supercharging WordPress for SEOAffiliate Summit
 
Web REST APIs Design Principles
Web REST APIs Design PrinciplesWeb REST APIs Design Principles
Web REST APIs Design PrinciplesAnji Beeravalli
 
How to Rock Your Video Marketing
How to Rock Your Video MarketingHow to Rock Your Video Marketing
How to Rock Your Video MarketingPixability
 
Dave Coleman slides from Learning Gateway Conference
Dave Coleman slides from Learning Gateway ConferenceDave Coleman slides from Learning Gateway Conference
Dave Coleman slides from Learning Gateway Conferencepearce.alex
 
August 10th, 2009 Tom Rogers YouTube
August 10th, 2009 Tom Rogers YouTubeAugust 10th, 2009 Tom Rogers YouTube
August 10th, 2009 Tom Rogers YouTubeStraight North
 
RESTful SOA - 中科院暑期讲座
RESTful SOA - 中科院暑期讲座RESTful SOA - 中科院暑期讲座
RESTful SOA - 中科院暑期讲座Li Yi
 
Pentesting Rest API's by :- Gaurang Bhatnagar
Pentesting Rest API's by :- Gaurang BhatnagarPentesting Rest API's by :- Gaurang Bhatnagar
Pentesting Rest API's by :- Gaurang BhatnagarOWASP Delhi
 
SES SF 2010 - Whats Next for SEO and News
SES SF 2010 - Whats Next for SEO and NewsSES SF 2010 - Whats Next for SEO and News
SES SF 2010 - Whats Next for SEO and NewsTopher Kohan
 
How to Use Online Video for Marketing
How to Use Online Video for MarketingHow to Use Online Video for Marketing
How to Use Online Video for MarketingHubSpot
 
The Zeitgeist Movement
The Zeitgeist MovementThe Zeitgeist Movement
The Zeitgeist Movementguest915c8c5
 

Similar to YouTube API: Dive In (20)

SEO And Podcasting Presentation
SEO And Podcasting PresentationSEO And Podcasting Presentation
SEO And Podcasting Presentation
 
Seo And Podcasting Presentation
Seo And Podcasting PresentationSeo And Podcasting Presentation
Seo And Podcasting Presentation
 
SMX@adtech: Mobile, Local and Video Search — Drew Hubbard
SMX@adtech: Mobile, Local and Video Search — Drew HubbardSMX@adtech: Mobile, Local and Video Search — Drew Hubbard
SMX@adtech: Mobile, Local and Video Search — Drew Hubbard
 
Multimedia Accessibility - CALRG '09
Multimedia Accessibility - CALRG '09Multimedia Accessibility - CALRG '09
Multimedia Accessibility - CALRG '09
 
Restful design at work v2.0
Restful design at work v2.0Restful design at work v2.0
Restful design at work v2.0
 
MALT Wiki and oEmbed
MALT Wiki and oEmbedMALT Wiki and oEmbed
MALT Wiki and oEmbed
 
API-Craft NYC - Overview of the Twitter APIs with demos
API-Craft NYC - Overview of the Twitter APIs with demosAPI-Craft NYC - Overview of the Twitter APIs with demos
API-Craft NYC - Overview of the Twitter APIs with demos
 
Flavours of SEO
Flavours of SEOFlavours of SEO
Flavours of SEO
 
Drupal Camp 2009 Pune Ilovebollycase Study 1233568636712224 1
Drupal Camp 2009 Pune Ilovebollycase Study 1233568636712224 1Drupal Camp 2009 Pune Ilovebollycase Study 1233568636712224 1
Drupal Camp 2009 Pune Ilovebollycase Study 1233568636712224 1
 
Supercharging WordPress for SEO
Supercharging WordPress for SEOSupercharging WordPress for SEO
Supercharging WordPress for SEO
 
Web REST APIs Design Principles
Web REST APIs Design PrinciplesWeb REST APIs Design Principles
Web REST APIs Design Principles
 
How to Rock Your Video Marketing
How to Rock Your Video MarketingHow to Rock Your Video Marketing
How to Rock Your Video Marketing
 
Dave Coleman slides from Learning Gateway Conference
Dave Coleman slides from Learning Gateway ConferenceDave Coleman slides from Learning Gateway Conference
Dave Coleman slides from Learning Gateway Conference
 
August 10th, 2009 Tom Rogers YouTube
August 10th, 2009 Tom Rogers YouTubeAugust 10th, 2009 Tom Rogers YouTube
August 10th, 2009 Tom Rogers YouTube
 
RESTful SOA - 中科院暑期讲座
RESTful SOA - 中科院暑期讲座RESTful SOA - 中科院暑期讲座
RESTful SOA - 中科院暑期讲座
 
Pentesting Rest API's by :- Gaurang Bhatnagar
Pentesting Rest API's by :- Gaurang BhatnagarPentesting Rest API's by :- Gaurang Bhatnagar
Pentesting Rest API's by :- Gaurang Bhatnagar
 
SES SF 2010 - Whats Next for SEO and News
SES SF 2010 - Whats Next for SEO and NewsSES SF 2010 - Whats Next for SEO and News
SES SF 2010 - Whats Next for SEO and News
 
Carpe VM
Carpe VMCarpe VM
Carpe VM
 
How to Use Online Video for Marketing
How to Use Online Video for MarketingHow to Use Online Video for Marketing
How to Use Online Video for Marketing
 
The Zeitgeist Movement
The Zeitgeist MovementThe Zeitgeist Movement
The Zeitgeist Movement
 

Recently uploaded

#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 

Recently uploaded (20)

#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 

YouTube API: Dive In

  • 1. YouTube API: Dive-In HigEdWebDev 2009 Ron West
  • 2. Google's mission …is to organize the world's information and make it universally accessible and useful. Sometimes making information accessible requires making it available in contexts other than a web browser.
  • 3. Agenda Introduction Getting Started Get Content Interaction Pulling it Together Developer Community
  • 4. Introduction YouTube in Review REST Google Data API YouTube Data API Entries/Feeds Authentication
  • 5.
  • 12.
  • 13. REST Client-Server Stateless Cacheable Uniform Interface Layered
  • 14. REST HTTP Methods Get = List or Retrieve Put = Replace or Update Post = Create Delete = Delete
  • 15.
  • 16. Lanugage, platform and transport agnostic
  • 17.
  • 18. Harder to develop with (requires tools)SOAP (RPC/Doc Literal) Web Services
  • 19.
  • 20. Simpler to develop than SOAP
  • 21.
  • 22. Tied to HTTP transportREST Web Services
  • 23.
  • 30.
  • 31. Response Codes Same response codes for HTTP 200, 201, 301, 400, 500 etc.. Codes have similar meaning for each type of call 200 (OK) 400 (Bad Request) 401 (Not Authorized) 404 (Not Found) 500 (Internal Error) Accompanied with error details (XML in payload)
  • 32. YouTube Data API Version 1 Version 2 (recommended)
  • 33. YouTubeData API Search for Videos Keywords (tags) Categories Query Params (metadata) Search for Playlists Keywords (tags) Categories Search for Channels Keywords (tags) Categories
  • 34. YouTube Data API Retrieve Videos Comments Captions Related Videos Video Responses Categories Keywords Playlists Subscriptions Profiles Contacts Messages Activity Feeds Insight Data Feed Favorites
  • 35. YouTube Data API (cont.) Create Videos Comments Captions Related Videos Video Responses Complaint Rating Contact Message Favorite Playlist Subscription
  • 36. YouTube Data API (cont.) Update Video Metadata Captions Profiles Playlists Contacts Delete Video Message Favorite Playlist Subscription Contact
  • 37. YouTube Data API Batch Processing Process multiple types of calls in a single request Each Request in its own <entry> tag
  • 38. Sample Interaction Query API for videos tagged with “SHU” Display Videos in List Allow user to Select Video to Display Display Single Video Retrieve Comments for that Video Post Comment Login Add to Playlist
  • 39. Feed <feed [namespaces]> … metadata … <openSearch:totalResults /> <openSearch:startIndex /> <openSearch: itemsPerPage /> <entry> … metadata … <media:group/> </entry> <entry> … metadata … <media:group/> </entry> … </feed>
  • 40. Entry (video) <entry [namespaces]> <title/> <content/> … metadata … <link rel=“http://gdata.youtube.com/schemas/2007#video.responses “/> <link rel=“http://gdata.youtube.com/schemas/2007#video.related” /> <link rel=“http://gdata.youtube.com/schemas/2007#mobile”/> <media:group> <media:contentyt:format=“t” url=“…”/> <media:thumbnailurl=“…” width=“…” height=“…”/> <yt: duration /> <yt:videoid /> </ media:group > </entry>
  • 41. Authentication AuthSub – YouTube Authentication with “callback” API [difficult] OAuth – Standardized Approach (similar in nature to OpenID) [most difficult] ClientLogin – Custom Authentication – you call YouTube API track token [easiest]
  • 42. Getting Started Google Developers Key Development Environment Samples
  • 43. Google Developers Key http://code.google.com/apis/youtube/dashboard/
  • 44. Development Environment Accessing dev servers Plugging in Developers Key
  • 45. Getting YouTube Content Standard Feeds Discovering Videos Channels Playlists Displaying Videos
  • 46. Standard Feeds http://code.google.com/apis/youtube/2.0/reference.html#Standard_feeds Top Rated Top Favorites Most Viewed Most Popular Most Recent Etc… Filter by Time Filter by Region Filter by Category
  • 47. Discovering Videos Keywords Categories Categories/Keywords Users
  • 48. Categories http://gdata.youtube.com/schemas/2007/categories.cat <app:categories [namespaces]> <atom:category term="Film" label="Film & Animation" xml:lang="en-US"> <yt:assignable/> <yt:browsable regions="AU BR CA CZ DE ES FR GB HK IE IL IN IT JP KR MX NL NZ PL PT RU SE TW US"/> </atom:category> </app>
  • 49. Video by Keyword/Tag http://gdata.youtube.com/feeds/api/videos/ Append /-/keyword/ to video feed URL Use query string ?category=keyword Not (-) Or (|) /-/Kennedy/-Bobby/-Ted/-Patrick /-/Kennedy/Bobby|Ted|Patrick
  • 50. Video by Category http://gdata.youtube.com/feeds/api/videos/ Append /-/Category/ to video feed URL Use query string ?category=Category Multiple Categories /-/Comedy/Music/Shortmov/ ?category=Comedy,Music,Shortmov Category ARE case sensitive
  • 51. Channels http://gdata.youtube.com/feeds/api/channels?v=2 Search just like videos using “?q=keywords/tags” <feed [namespaces> … metadata … <openSearch:totalResults /> <openSearch:startIndex /> <openSearch: itemsPerPage /> <entry> <title /> <summary /> <gd:feedlinkurl=“…” hitcount=“…”> </entry> </feed>
  • 52. Playlists http://gdata.youtube.com/feeds/api/playlists/snippets?v=2 Searchjustlike a Channel <feed [namespaces> … metadata … <openSearch:totalResults /> <openSearch:startIndex /> <openSearch: itemsPerPage /> <entry> <title /> <summary /> <content src=“…”> <yt:countHint /> <yt:playlistId /> </entry> </feed>
  • 54. Interacting with YouTube Content Authentication Comments Ratings Updating Uploading
  • 55. ClientLogin https://www.google.com/youtube/accounts/ClientLogin Pass in: Email Passwd Receive: Auth=AIwbFARksypDdUSGGYRI_5v7Z9TaijoPQqpIfCEjTFPAikn_---OC-I1VJtQ YouTubeUser=testuser Send into all requests: Header: Authorization = “GoogleLogin auth= AIwbFARksypDdUSGGYRI_5v7Z9TaijoPQqpIfCEjTFPAikn_---OC-I1VJtQ”
  • 56. Comments Get Video Feed Look for: <gd:comments> <gd:feedlinkhref=“…” countHint=“…” /> </gd:comments> Pass in
  • 57. Ratings Link embeded in the video feed <link rel='http://gdata.youtube.com/schemas/2007#video.ratings' type='application/atom+xml' href='http://gdata.youtube.com/feeds/api/videos/VIDEO_ID/ratings'/> Send back to this URL: <entry [namespaces]> <gd:rating value="4" min="1" max="5"/> </entry>
  • 58. Updating Link embeded in the video feed <link rel='edit' type='application/atom+xml' href='http://gdata.youtube.com/feeds/api/users/andyland74/uploads/914IMX9RSTE'> Send Back to this URL: <entry [namespaces]> <media:group> <media:title type=“…“ /> <media:description type=“…“ /> <media:category scheme=“…“ /> <media:keywords /> </media:group> </entry>
  • 59. Uploading http://uploads.gdata.youtube.com/feeds/api/users Include in Header Authentication Slug (filename) Include in Body Video File <entry [namespace]> <media:group> <media:title type=”...” /> <media:description type=“…“ /> <media:keywords /> <media:categoryscheme=“…“ /> </media:group> </entry>
  • 60. Challenges Documentation is poor No true congruity in related links Error messages are non-descriptive
  • 61. Developer Resources Google Group http://groups.google.com/group/youtube-api-gdata Google Code Help http://code.google.com/support/bin/topic.py?topic=12357
  • 62. Contact Ron West @notronwest facebook.com/notronwest www.notronwest.com/blog